You are here: Building the Logic > Operation Logic
Operation logic defines what happens to an entity when it enters a location. Operation logic is optional, but typically contains at least a WAIT statement for the amount of time the entity should spend at the location. For modeling purposes, the exact nature of the operation (joining, grouping, etc.) is irrelevant. What is essential is to know what happens in terms of the time consumed, the resources used, and any other logic that impacts system performance. For operations requiring more than a time and resource designation, detailed logic may need to be defined using IF...THEN or action statements.
Special operation statements are provided to define the activities that are to occur. By using operation logic, any of the following activities can be defined:
Detain an entity for a specified length of time while an activity is performed.
Detain an entity until one or more resources are obtained.
Detain an entity until one or more additional entities are joined to it.
Detach one or more entities from the current entity.
Consolidate one or more entities into a group.
Separate an entity into two or more entities.
Detain an entity until a particular system condition is reached.
Destroy an entity.
Create one or more new entities.
Execute a block of logic (assignment of variables, etc.).
Signal the start of some other action in the system (e.g., place an order).
Make some decision about further routing.
Statements can be typed directly into the operation field, or inside a larger logic window after double-clicking in the field or clicking on the Operation button. Alternatively, the Logic Builder can help build logic and is accessed by clicking the right mouse button inside the operation field or logic window. All statements, functions, and distributions available in the operation field are discussed in detail, including examples, in Statements and Functions.
Example
Each entity processes the operation statements defined for it at a particular location, independent of other operations performed on other entities at the same location. The following example presents the operation logic for an entity joining an entity, EntB, and renaming the entity as EntC.